
Chapter 34. GPS Mapping and Geotagged Images : Geotagging

From the website:

  Killer Game Programming in Java
  http://fivedots.coe.psu.ac.th/~ad/jg

  Dr. Andrew Davison
  Dept. of Computer Engineering
  Prince of Songkla University
  Hat yai, Songkhla 90112, Thailand
  E-mail: ad@fivedots.coe.psu.ac.th


If you use this code, please mention my name, and include a link
to the website.

Thanks,
  Andrew

============================

Topics: reading and writing geotagged information using the
        command line ExifTool tool and the Sanselan API.


Directory contents:

There are 4 Java files:
  * MDViewer.java
  * MetaDataUtils.java
  * GPSTagTests.java
  * GeoMath.java
    This class is duplicated in 3 folders -- 
       in JMapViewer Tests/, Panoramio Search/, and Geotagging/

Two test images:
   * engSign.jpg
   * library.jpg   (has no Exif metadata)

There are 3 batch files:
  * stampGPS.bat
  - this assumes that exiftool.exe is in the current directory

  * compile.bat
  * run.bat
  - both batch files assume:
    * sanselan-0.97-incubator.jar is installed in c:\sanselan\

----------------------------
Compilation:

  > compile *.java

----------------------------
Execution:

  > stampGPS <latitude> <longitude> <JPG file>
e.g.
  > stampGPS 53.314401 -2.255305 library.jpg


  > run MDViewer <JPG file>
e.g.
  > run MDViewer library.jpg


  > run GPSTagTests <latitude> <longitude> <JPG file>
e.g.
  > run GPSTagTests 53.314401 -2.255305 library.jpg


----------------------------
ExifTool 
  http://www.sno.phy.queensu.ca/~phil/exiftool/

I downloaded the Windows executable
  exiftool-8.37.zip

I unzipped it, and renamed it to exiftool.exe

Usage:
  exiftool engSign.jpg

----------------------------
The Sanselan API 
   http://commons.apache.org/sanselan/

I downloaded
  apache-sanselan-incubating-0.97-bin.zip

I unzipped it and **renamed** sanselan-0.97-incubator\
to be the folder c:\sanselan\

---------
Last updated: 8th November 2010
